<!--
*Author：富行天下团队

 *代码由框架生成,任何更改都可能导致被代码生成器覆盖
 *业务请在@/extension/mall/Form.js此处编写
 -->
<template>
  <div>
    <view-grid ref="grid"
               :columns="columns"
               :detail="detail"
               :editFormFields="editFormFields"
               :editFormFileds="editFormFields"
               :editFormOptions="editFormOptions"
               :searchFormFields="searchFormFields"
               :searchFormFileds="searchFormFields"
               :searchFormOptions="searchFormOptions"
               :table="table"
               :extend="extend">
    </view-grid>
  </div>
</template>

<script>
import extend from "@/extension/mall/Form.js";
import ViewGrid from "@/components/basic/ViewGrid.vue";
var vueParam = {
  components: {
    ViewGrid
  },
  data () {
    return {
      table: {
        key: 'id',
        footer: "Foots",
        cnName: '表单设置',
        name: 'Form',
        url: "/Form/",
        sortName: "id"
      },
      extend: extend,
      editFormFields: { "form_name": "",form_type: '',merchantCode:"",merchantName:"" },
      editFormOptions: [[
        { field: 'form_name', "title": "表单名称", "required": true, "type": "text", min: 0, colSize: 11 },
        {
            title: "表单类型",
            field: "form_type",
            type: "select",
            dataKey: "form_type",
            data: [],
          },],],
      searchFormFields: { "form_name": "","form_type":""},
      searchFormOptions: [[{"title":"表单名称","field":"form_name","type":"like"},{"title":"表单类型","field":"form_type","dataKey":"form_type","type":"select"},{"title":"创建时间","field":"createDate","type":"datetime"},]],
      columns: [{ field: 'id', title: '主键', type: 'int', width: 90, hidden: true, readonly: true, require: true, align: 'left' },
      { field: 'form_name', title: '表单名称', type: 'string', width: 120, align: 'left', sortable: true },
      { field: 'form_type', title: '表单类型', type: 'string', width: 120, align: 'left', bind: { key: 'form_type', data: [] } },
      { field: 'form_configuration', title: '表单配置', type: 'string', width: 220, align: 'left' },
      { field: 'designer_configuration', title: '设计器配置', type: 'string', width: 220, align: 'left' },
      // { field: 'form_parameter', title: '表单参数', type: 'string', width: 220, align: 'left' },
      { field: 'table_configuration', title: '表格配置', type: 'string', width: 220, align: 'left' },
      // { field: 'merchantCode', title: '商户编码', type: 'string', width: 220, align: 'left' },
      // { field: 'merchantName', title: '商户名称', type: 'string', width: 220, align: 'left' },
      { field: 'createID', title: '创建人ID', type: 'int', width: 90, hidden: true, align: 'left' },
      { field: 'creator', title: '创建人', type: 'string', width: 180, align: 'left' },
      { field: 'createDate', title: '创建时间', type: 'datetime', width: 190, align: 'left', sortable: true },
        // { field: 'modifier', title: '修改人', type: 'string', width: 180, align: 'left' },
        // { field: 'modifyDate', title: '修改时间', type: 'datetime', width: 90, align: 'left', sortable: true },
        // { field: 'modifyID', title: '修改人ID', type: 'int', width: 90, hidden: true, align: 'left' }
      ],
      detail: {
        cnName: "#detailCnName",
        columns: [],
        sortName: "",
        key: ""
      }
    };
  }
};
export default vueParam;
</script>
